<template>
  <v-card>
    <v-list dense>
      <v-list-item-group>
        <v-subheader class="headline font-weight-bold">未完成的计划：</v-subheader>
        <v-list-item v-for="(event,index) in eventList"
                     :key="event[1]"
                     @click="changeStatus(index)">
          <v-checkbox v-model="checkbox"></v-checkbox>
          <v-list-item-content>
            <v-list-item-title v-text="event[1]"></v-list-item-title>
          </v-list-item-content>
        </v-list-item>
      </v-list-item-group>
    </v-list>
  </v-card>
</template>

<script>
export default {
  name: 'FinishedList',
  props: ['eventList'],
  data () {
    return {
      checkbox: true
    }
  },
  methods: {
    changeStatus (index) {
      this.$emit('statusChange', this.eventList[index][1])
    }
  },
};
</script>

<style scoped>
</style>
